import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:fun_shop/src/routes/router_config.dart';
import 'package:fun_shop/src/view_model/theme_model.dart';
import 'package:provider/provider.dart';

class FunShop extends StatelessWidget {
  const FunShop({super.key});

  @override
  Widget build(BuildContext context) {
    return Consumer<ThemeModel>(
      builder: (context, vm, child) {
        return ScreenUtilInit(
          designSize: const Size(750, 1334),
          child: MaterialApp.router(
            debugShowCheckedModeBanner: false,
            routerConfig: routerConfig,
            title: 'Fun Shop',
            theme: vm.currentTheme,
            // theme: ThemeData(
            //   useMaterial3: true,
            //   colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepOrange)
            // ),
          ),
        );
      },
    );
  }
}